ArrayList<Integer> cardCompare(String card1, String card2) {
    // 将卡片分为数字和花色
    int number1 = Integer.parseInt(card1.substring(0, card1.length() - 1));
    int number2 = Integer.parseInt(card2.substring(0, card2.length() - 1));
    char suit1 = card1.charAt(card1.length() - 1);
    char suit2 = card2.charAt(card2.length() - 1);

    // 定义花色优先级
    String suitPriority = "HCDS";

    // 比较花色
    if (suitPriority.indexOf(suit1) < suitPriority.indexOf(suit2)) {
        return new ArrayList<>(List.of(-1));
    } else if (suitPriority.indexOf(suit1) > suitPriority.indexOf(suit2)) {
        return new ArrayList<>(List.of(1));
    } else {
        // 如果花色相同，则比较数字
        if (number1 < number2) {
            return new ArrayList<>(List.of(-1));
        } else if (number1 > number2) {
            return new ArrayList<>(List.of(1));
        } else {
            return new ArrayList<>(List.of(0));
        }
    }
}